package com.knowswift.security.account;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.knowswift.common.bean.project.vo.ModulePermissionVO;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import java.util.List;

@Data
@JsonInclude(JsonInclude.Include.NON_NULL)
public class UserVO {

    private String userId;
    private String nickname;
    private String userAvatar;
    @NotBlank(message = "登录账号不可为空")
    private String userAccount;
    private Double locationLongitude;
    private Double locationLatitude;
    @NotBlank(message = "岗位不可为空")
    private String userPosition;
    private String userPhone;
    private String role;
    private Boolean subscribed;
    private Boolean locked;
    private String pushCid;
    private Boolean receivePush;
    @NotEmpty(message = "权限列表不可为空")
    private List<Authority> userAuthorities;

    // 非数据库字段
    private String token;

    private Long pageNo;
    private Long pageSize;

    private String iv;
    private String encryptedData;
    private String oldPassword;
    private String newPassword;
    private String loginPassword;
    private String verifyCode;

    private List<ModulePermissionVO> projectLimitList;
}